﻿using System;
using System.Xml.Serialization;
using ICalendar.CalendarProperties;

namespace ICalendar.CalendarProperties
{
    /// <summary>
    /// This property defines a Uniform Resource Locator (URL) associated with the iCalendar object.
    /// </summary>
    [Serializable]
    [XmlRoot("url")]  
    public class Url : CalendarPropertyBase<Uri>
    {
        protected override void SetValue(string value)
        {
            this.Value = new Uri(value);
        }

        protected override string GetValue()
        {
            return Value.ToString();
        }

        protected override void SetParametersFromXParameters(XParameterCollection xparams)
        {
            
        }

        protected override XParameterCollection GetXParametersFromParameters()
        {
            return null;
        }

        protected override string[] GetXReservedParametersNames()
        {
            return null;
        }
    }
}